package com.booktrade.service;

import com.booktrade.dto.OrderDTO;
import com.booktrade.dto.OrderRequestDTO;
import com.booktrade.entity.Orders;
import com.baomidou.mybatisplus.extension.service.IService;
import com.booktrade.vo.OrderVo;

import java.util.List;

/**
 * <p>
 * 订单表，存储用户购买的订单信息 服务类
 * </p>
 */
public interface IOrdersService extends IService<Orders> {

    List<OrderVo> getOrdersByBuyerId(Integer buyerId,String statusDTO);

    boolean confirmReceipt(Integer orderId, Integer buyerId);

    List<OrderVo> getOrdersBySellerId(Integer sellerId,String statusDTO);

    boolean shipOrder(Integer orderId, Integer sellerId);

    boolean requestRefund(Integer orderId, Integer buyerId);

    List<Integer> saveOrder(OrderRequestDTO orderRequestDTO, Integer buyerId);
}
